/*************************************************************
**    Filename  :
**
**    Author :  
**    Version :  
**    Date   :   
*************************************************************/

#ifndef __Os_Sem_H_
#define __Os_Sem_H_


typedef int mp_Os_Mutex_t;
typedef int mp_Os_Sem_t;


#ifdef __cplusplus
extern "C" {
#endif

int Os_MutexInit(void);
int Os_MutexDelete(mp_Os_Mutex_t);
int Os_MutexDestroy(mp_Os_Mutex_t);
int Os_MutexLock(mp_Os_Mutex_t);
int Os_MutexUnlock(mp_Os_Mutex_t);
int Os_MutexTrylock (int mid);
int Os_MutexTimedlock (int mid, int millisecond);


unsigned int Os_SemInit(unsigned int initialTokenCount);
int Os_SemDestroy (unsigned int sem_handle);
int Os_SemPost(unsigned int sem_handle);
int Os_SemWait(unsigned int sem_handle, unsigned int milliSecsToWait);

#ifdef __cplusplus
}
#endif

#endif

